<?php

namespace app\api\model;

class Article extends Base {


  public $searchFields = ['title', 'author'];
  

  public function setStatusById($id, $status) {

    $article = $this->find($id);
    $article->status = $status;
    return $article->save();

  }

}